﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="OutterAwards.aspx.cs" Inherits="Web.admin.OutterManage.OutterAwardsManage.OutterAwards" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
    <title>
        校级获奖等级
    </title>
    <script src="../../js/jquery-1.3.2.min.js" type="text/javascript"></script>
    <script src="../../js/jquery.form.js" type="text/javascript"></script>
    <link href="../../css/style.css" rel="stylesheet" type="text/css" />
    <script src="../../js/function.js" type="text/javascript"></script>
    <script language="javascript" type="text/javascript">
        function SingleUpload1(repath, uppath, iswater) {
            var submitUrl = "../tool/SingleUpload.ashx?ReFilePath=" + repath + "&UpFilePath=" + uppath;
            //判断是否打水印
            if (arguments.length == 3) {
                submitUrl = "../tool/SingleUpload.ashx?ReFilePath=" + repath + "&UpFilePath=" + uppath + "&IsWater=" + iswater;
            }
            //开始提交
            $("#form1").ajaxSubmit({
                beforeSubmit: function (formData, jqForm, options) {
                    //隐藏上传按钮
                    $("#" + repath).nextAll(".files").eq(0).hide();
                    //显示LOADING图片
                    $("#" + repath).nextAll(".uploading").eq(0).show();
                },
                success: function (data, textStatus) {
                    if (data.msg == 1) {
                        $("#" + repath).val(data.msbox);
                    } else {
                        alert(data.msbox);
                    }
                    $("#" + repath).nextAll(".files").eq(0).show();
                    $("#" + repath).nextAll(".uploading").eq(0).hide();
                },
                error: function (data, status, e) {
                    if (data.msg == 1) {
                        $("#" + repath).val(data.msbox);
                    } else {
                        alert(data.msbox);
                    }
                    $("#" + repath).nextAll(".files").eq(0).show();
                    $("#" + repath).nextAll(".uploading").eq(0).hide();
                },
                url: submitUrl,
                type: "post",
                dataType: "json",
                timeout: 600000
            });
        };
    </script>
</head>
<body>
    <form id="form1" runat="server">
    <div class="top_div">
        <div class="top_div_left" >
                <table>
                    <tr >
                        <td ><img  alt=""; src="../../images/main_hl.gif" /></td>
                        <td ><img alt=""; src="../../images/main_hl2.gif" /></td>
                        <td class="topNav"><span>获奖管理</span></td>
                        <td><img alt=""; src="../../images/main_hr.gif" /></td>
                    </tr>
                </table>
        </div>
    </div>
     <div class="middle_div">
        <div class="middle_left"></div>
        <div class="middle_middle">
            <div class="navigation"><span>首页&gt;校级竞赛任务&gt;获奖管理</span></div>
            <div class="tools_box">
                <div class="tools_bar">
                    <asp:HiddenField ID="ContestId" runat="server" />
                    <asp:LinkButton runat="server" CssClass="tools_btn" ID="btn_AddStudent" 
                        onclick="btnAddStudent_Click"><span><b class="delete">添加获奖学生</b></span></asp:LinkButton>
                    <asp:LinkButton runat="server" CssClass="tools_btn" ID="btn_AddGroup" 
                        onclick="btnAddGroup_Click"><span><b class="delete">添加获奖小组</b></span></asp:LinkButton>
                
                    <a href="#"  class="tools_btn" onclick="checkAll(this);"><span><b class="checkAll">全选</b></span></a>
                    <asp:LinkButton runat="server" OnClientClick="return confirm( '确定要删除此项内容吗？ ');" CssClass="tools_btn" ID="btn_Delete"><span><b class="delete">批量删除</b></span></asp:LinkButton>
                    <a href="#"  class="tools_btn"><span><b class="perms">预览</b></span></a>
                    <%--<a href="javascript:;" onclick="showDiv('picUpload')" class="tools_btn"><span><b class="delete">上传图片</b></span></a>--%>
                </div>
            </div>
            <div class="content_table">
                 <table class="msgtable" >
                 <asp:Repeater ID="RpList" runat="server">
                 <HeaderTemplate>
                      <tr>
                         <th>选择</th>                                
                         <th>所属竞赛</th>
                         <th>学生姓名</th>
                         <th>学生学号</th>
                         <th>所属班级</th> 
                         <th>所属学院</th>
                         <th>小组名称</th>                      
                         <th>获奖等级</th>
                         <th>是否专业组</th>
                         <th>操作</th>
                       </tr>
                 </HeaderTemplate>
                 <ItemTemplate>
                            <tr >
                                <td>
                                    <asp:CheckBox ID="CbChoose" CssClass="checkBox" runat="server" />
                                    <asp:HiddenField ID="Hf_id" runat="server" Value='<%#Eval("PAR_ID") %>' />
                                </td>
                                <td><%#Eval("CON_NAME")%> </td>
                                <td><%#Eval("STU_NAME")%></td>
                                <td><%#Eval("STU_CODE")%></td>
                                <td><%#Eval("CLA_NAME")%></td>
                                <td><%#Eval("ACA_NAME")%></td>                         
                                <td><%#Eval("GRO_NAME")%></td>
                                <td><%#Eval("PAR_AWARDS").ToString().Trim() == "-1" ? "否" : Eval("AWA_NAME")%></td>
                                <td><%#Eval("PAR_SPECIALTY").ToString().Trim() == "0" ? "否" : "是"%></td>                        
                                <td>
                                    <a href="awardStu.aspx?id=<%#Eval("PAR_ID") %>&OPERATION=Modify">修改</a>|
                                    <a href="awardStu.aspx?OPERATION=Delete&id=<%# Eval("PAR_ID") %>">删除</a>|
                                    <a href="../OutterPictures.aspx?id=<%#Eval("PAR_ID") %> ">获奖证书</a>
                                </td>
                            </tr>
                   </ItemTemplate>
                   </asp:Repeater>
                </table>
            </div>
        </div>
     </div>
     <div class="uploadPic" id="picUpload">
        <div class="Con_top">
            <div class="Con_close" onclick="hideDiv('picUpload')">X</div>
        </div>
        <div class="uploadPicMiddle">
            <table>
               <tr class="upordown" >
                    <th>添加图片：</th>
                    <td>
                         <input type="text" runat="server" id="txtImgUrl" readonly="readonly" class="txtInput txtInput_upload" style="display:block; float:left;padding:0px;" />
                         <a href="javascript:void(0);" style="float:left;" class="files">
                            <input type="file" id="FileUpload" name="FileUpload" onchange="SingleUpload1('txtImgUrl','FileUpload')" />
                        </a>
                         <span class="uploading">正在上传，请稍候...</span>
                    </td>
                </tr>
            </table>
        </div>
        <div class="Con_foot">
            <asp:Button ID="Button1" runat="server" OnClientClick="return check1();" Text="确认添加" />
            <input type="button" value="取消" onclick="hideDiv('picUpload')" />
        </div>
    </div>
    </form>
</body>
</html>
